﻿<UserControl
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
        xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
        xmlns:i="http://schemas.microsoft.com/expression/2010/interactivity" xmlns:GalaSoft_MvvmLight_Command="clr-namespace:GalaSoft.MvvmLight.Command;assembly=GalaSoft.MvvmLight.Extras.WPF4"
		x:Class="Drafter.EditView"
        mc:Ignorable="d" 
     
		Background="Black" d:DesignHeight="775.5" d:DesignWidth="1189">
    <UserControl.Resources>
    	<BooleanToVisibilityConverter x:Key="BooleanToVisibilityConverter1"/>
    	<BooleanToVisibilityConverter x:Key="BooleanToVisibilityConverter"/>
    	<Storyboard x:Key="ShowMenu">
    		<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="border">
    			<EasingDoubleKeyFrame KeyTime="0" Value="0"/>
    			<EasingDoubleKeyFrame KeyTime="0:0:0.5" Value="1"/>
    		</DoubleAnimationUsingKeyFrames>
    	</Storyboard>
    	<HierarchicalDataTemplate x:Key="ChapterTemplate" ItemsSource="{Binding Children}">
    		<StackPanel>
    			<TextBlock Text="{Binding Title}" Foreground="White"/>
    		</StackPanel>
    	</HierarchicalDataTemplate>
		<HierarchicalDataTemplate x:Key="SelectedChapterTemplate" ItemsSource="{Binding Children}">
    		<StackPanel>
    			<TextBlock Text="{Binding Title}" Foreground="Red"/>
    		</StackPanel>
    	</HierarchicalDataTemplate>
		 <Style TargetType="{x:Type TreeViewItem}"
           x:Key="ContainerStyle">
        <Setter Property="HeaderTemplate"
                Value="{StaticResource ChapterTemplate}" />
        <Style.Triggers>
            <Trigger Property="IsSelected"
                     Value="True">
                <Setter Property="HeaderTemplate"
                        Value="{StaticResource SelectedChapterTemplate}" />
            </Trigger>
        </Style.Triggers>
    </Style>
		
    	<Style x:Key="ButtonStyle2" TargetType="{x:Type Button}">
    		<Setter Property="Template">
    			<Setter.Value>
    				<ControlTemplate TargetType="{x:Type Button}">
    					<Grid Background="Black">
    						<Viewbox>
    							<Path Data="M188.75,97.0001L213.75,97.0001C215.407,97.0001,216.75,98.3432,216.75,100L216.75,115C216.75,116.657,215.407,118,213.75,118L188.75,118C187.093,118,185.75,116.657,185.75,115L185.75,100C185.75,98.3432,187.093,97.0001,188.75,97.0001z M216.281,129.333L241.281,129.333C242.938,129.333,244.281,130.676,244.281,132.333L244.281,147.333C244.281,148.99,242.938,150.333,241.281,150.333L216.281,150.333C214.624,150.333,213.281,148.99,213.281,147.333L213.281,132.333C213.281,130.676,214.624,129.333,216.281,129.333z M216.281,162.167L241.281,162.167C242.938,162.167,244.281,163.51,244.281,165.167L244.281,180.167C244.281,181.823,242.938,183.167,241.281,183.167L216.281,183.167C214.624,183.167,213.281,181.823,213.281,180.167L213.281,165.167C213.281,163.51,214.624,162.167,216.281,162.167z M200.448,118.667L200.448,172 213.26,171.979 M200.198,140.729L213.469,140.729" Fill="#FF000000" Stretch="Fill" Stroke="{TemplateBinding Foreground}" StrokeThickness="5" StrokeLineJoin="Round" Height="66.733" Width="47.536" HorizontalAlignment="Left" VerticalAlignment="Bottom"/>
    						</Viewbox>
    					</Grid>
    					<ControlTemplate.Triggers>
    						<Trigger Property="IsFocused" Value="True"/>
    						<Trigger Property="IsDefaulted" Value="True"/>
    						<Trigger Property="IsMouseOver" Value="True"/>
    						<Trigger Property="IsPressed" Value="True"/>
    						<Trigger Property="IsEnabled" Value="False"/>
    					</ControlTemplate.Triggers>
    				</ControlTemplate>
    			</Setter.Value>
    		</Setter>
    	</Style>
    	<Style x:Key="TreeViewItemStyle1" TargetType="{x:Type TreeViewItem}">
    		<Setter Property="IsExpanded" Value="{Binding IsExpanded, Mode=TwoWay}" />
     		<Setter Property="IsSelected" Value="{Binding IsSelected, Mode=TwoWay}" />
    		<Setter Property="HeaderTemplate"
    			Value="{StaticResource ChapterTemplate}" />
    		<Style.Triggers>
    			<Trigger Property="IsSelected"
    				Value="True">
    				<Setter Property="HeaderTemplate"
    					Value="{StaticResource SelectedChapterTemplate}" />
    			</Trigger>
    		</Style.Triggers>
    	</Style>

    </UserControl.Resources>


    <UserControl.DataContext>
        <Binding Path="Edit" Source="{StaticResource Locator}"/>
    </UserControl.DataContext>

    <UserControl.InputBindings>
        <KeyBinding Command="{Binding CloseApplicationCommand}" Key="Escape"/>
        <KeyBinding Command="{Binding OpenFileCommand}" Key="O" Modifiers="Control"/>
        <KeyBinding Command="{Binding SaveFileCommand}" Key="S" Modifiers="Control"/>
        <KeyBinding Command="{Binding NewFileCommand}" Key="N" Modifiers="Control"/>
        <KeyBinding Command="{Binding PrintCommand}" Key="P" Modifiers="Control"/>
        <KeyBinding Command="{Binding ExportCommand}" Key="E" Modifiers="Control"/>
        <KeyBinding Command="{Binding SaveFileAsCommand}" Key="S" Modifiers="Control+Shift"/>
    </UserControl.InputBindings>
    <Grid Margin="0,0,2,2">
        <Grid.RowDefinitions>
            <RowDefinition Height="35" />
            <RowDefinition Height="*"/>
            <RowDefinition Height="35" />
        </Grid.RowDefinitions>
        <Grid.ColumnDefinitions>
            <ColumnDefinition Width="50"/>
            <ColumnDefinition Width="*"/>
            <ColumnDefinition Width="100"/>
        </Grid.ColumnDefinitions>
        <Grid x:Name="threeColumnGrid" Grid.Row="1" Grid.ColumnSpan="3" >
            <Grid.ColumnDefinitions>
                <ColumnDefinition Width="0.25*"/>
                <ColumnDefinition  Width="Auto"/>
                <ColumnDefinition Width="0.50*"/>
                <ColumnDefinition  Width="Auto"/>
                <ColumnDefinition Width="0.25*"/>
            </Grid.ColumnDefinitions>
            <DockPanel x:Name="outlinePanel" Visibility="{Binding OutlineVisible, Converter={StaticResource BooleanToVisibilityConverter1}}">

        		<TextBox Text="{Binding DraftViewModel.Title, Mode=TwoWay}" FontSize="24" Foreground="#FF6E6E6E" FontStyle="Italic" FontWeight="Bold" BorderBrush="{x:Null}" Background="#FF030303" Height="35" d:LayoutOverrides="Height" VerticalAlignment="Center" DockPanel.Dock="Top" HorizontalAlignment="Center" IsTabStop="False" />
        		<StackPanel x:Name="treeButtonsPanel" DockPanel.Dock="Bottom" Orientation="Horizontal" HorizontalAlignment="Center">
        			<Viewbox Height="35" d:LayoutOverrides="Height">
        				<Path Data="M378.9751,276.3999L378.9751,270.0249 372.5991,270.0249C371.7721,270.0249,371.1001,269.3529,371.1001,268.5259L371.1001,261.4729C371.1001,260.6459,371.7721,259.9739,372.5991,259.9739L378.9751,259.9739 378.9751,253.5989C378.9751,252.7719,379.6471,252.0999,380.4741,252.0999L387.5271,252.0999C388.3541,252.0999,389.0261,252.7719,389.0261,253.5989L389.0261,259.9739 395.4001,259.9739C396.2271,259.9739,396.8991,260.6459,396.8991,261.4729L396.8991,268.5259C396.8991,269.3529,396.2271,270.0249,395.4001,270.0249L389.0261,270.0249 389.0261,276.3999C389.0261,277.2269,388.3541,277.8989,387.5271,277.8989L380.4741,277.8989C379.6471,277.8989,378.9751,277.2269,378.9751,276.3999" Fill="#FF6E6E6E" Stretch="Fill" RenderTransformOrigin="0.606,-11.012" Width="47.216" Height="50" VerticalAlignment="Bottom">
        					<i:Interaction.Triggers>
        						<i:EventTrigger EventName="MouseLeftButtonDown">
        							<GalaSoft_MvvmLight_Command:EventToCommand  CommandParameter="{Binding SelectedItem, ElementName=treeView1}" Command="{Binding DraftViewModel.CreateRootChapterCommand, Mode=OneWay}" />
        						</i:EventTrigger>
        					</i:Interaction.Triggers>
        				</Path>
        			</Viewbox>
        			<Viewbox Height="35" d:LayoutOverrides="Height">
        				<Path Data="M378.9751,276.3999L378.9751,270.0249 372.5991,270.0249C371.7721,270.0249,371.1001,269.3529,371.1001,268.5259L371.1001,261.4729C371.1001,260.6459,371.7721,259.9739,372.5991,259.9739L378.9751,259.9739 378.9751,253.5989C378.9751,252.7719,379.6471,252.0999,380.4741,252.0999L387.5271,252.0999C388.3541,252.0999,389.0261,252.7719,389.0261,253.5989L389.0261,259.9739 395.4001,259.9739C396.2271,259.9739,396.8991,260.6459,396.8991,261.4729L396.8991,268.5259C396.8991,269.3529,396.2271,270.0249,395.4001,270.0249L389.0261,270.0249 389.0261,276.3999C389.0261,277.2269,388.3541,277.8989,387.5271,277.8989L380.4741,277.8989C379.6471,277.8989,378.9751,277.2269,378.9751,276.3999" Fill="#FF6E6E6E" Stretch="Fill" RenderTransformOrigin="0.606,-11.012" Width="47.216" Height="50" VerticalAlignment="Bottom" DataContext="{Binding SelectedItem, ElementName=treeView1, Mode=OneWay}" >
        					<i:Interaction.Triggers>
        						<i:EventTrigger EventName="MouseLeftButtonDown">
        							<GalaSoft_MvvmLight_Command:EventToCommand CommandParameter="{Binding SelectedItem, ElementName=treeView1}" Command="{Binding CreateChildChapterCommand, Mode=OneWay}"/>
        						</i:EventTrigger>
        					</i:Interaction.Triggers>
        				</Path>
        			</Viewbox>
        			<Viewbox Height="35" d:LayoutOverrides="Height">
        				<Path Data="M929.7959,516.2285L918.1589,516.2285 918.1579,505.4445 912.3449,505.4435 923.9719,493.7695 935.6539,505.3875 929.7969,505.4455z" Fill="#FF6E6E6E" Stretch="Fill" RenderTransformOrigin="0.606,-11.012" Width="47.216" Height="50" VerticalAlignment="Bottom" DataContext="{Binding SelectedItem, ElementName=treeView1, Mode=OneWay}">
        					<i:Interaction.Triggers>
        						<i:EventTrigger EventName="MouseLeftButtonDown">
        							<GalaSoft_MvvmLight_Command:EventToCommand CommandParameter="{Binding SelectedItem, ElementName=treeView1}" Command="{Binding GoUpCommand, Mode=OneWay}"/>
        						</i:EventTrigger>
        					</i:Interaction.Triggers>
        				</Path>
        			</Viewbox>
        			<Viewbox Height="35" d:LayoutOverrides="Height">
        				<Path Data="M869.7998,493.7715L858.1708,493.7715 858.1708,504.5435 852.3418,504.5435 863.9708,516.2285 875.6568,504.6145 869.7998,504.5435z" Fill="#FF6E6E6E" Stretch="Fill" RenderTransformOrigin="0.606,-11.012" Width="47.216" Height="50" VerticalAlignment="Bottom" DataContext="{Binding SelectedItem, ElementName=treeView1, Mode=OneWay}" >
        					<i:Interaction.Triggers>
        						<i:EventTrigger EventName="MouseLeftButtonDown">
        							<GalaSoft_MvvmLight_Command:EventToCommand CommandParameter="{Binding SelectedItem, ElementName=treeView1}" Command="{Binding GoDownCommand, Mode=OneWay}"/>
        						</i:EventTrigger>
        					</i:Interaction.Triggers>
        				</Path>
        			</Viewbox>
        			<Viewbox Height="35" d:LayoutOverrides="Height">
        				<Path Data="M732.7695,510.7959L732.7695,499.1589 743.5545,499.1579 743.5555,493.3449 755.2285,504.9719 743.6115,516.6539 743.5535,510.7969z" Fill="#FF6E6E6E" Stretch="Fill" RenderTransformOrigin="0.606,-11.012" Width="47.216" Height="50" VerticalAlignment="Bottom" >
        					<i:Interaction.Triggers>
        						<i:EventTrigger EventName="MouseLeftButtonDown">
        							<GalaSoft_MvvmLight_Command:EventToCommand Command="{Binding NavigateToCommand, Mode=OneWay}" CommandParameter="Options" />
        						</i:EventTrigger>
        					</i:Interaction.Triggers>
        				</Path>
        			</Viewbox>
        			<Viewbox Height="35" d:LayoutOverrides="Height">
        				<Path Data="M815.2285,510.7959L815.2285,499.1589 804.4445,499.1579 804.4435,493.3449 792.7695,504.9719 804.3875,516.6539 804.4455,510.7969z" Fill="#FF6E6E6E" Stretch="Fill" RenderTransformOrigin="0.606,-11.012" Width="47.216" Height="50" VerticalAlignment="Bottom" >
        					<i:Interaction.Triggers>
        						<i:EventTrigger EventName="MouseLeftButtonDown">
        							<GalaSoft_MvvmLight_Command:EventToCommand Command="{Binding NavigateToCommand, Mode=OneWay}" CommandParameter="Options" />
        						</i:EventTrigger>
        					</i:Interaction.Triggers>
        				</Path>
        			</Viewbox>
        		</StackPanel>

        		<TreeView x:Name="treeView1" Background="#FF2D2D2D" Foreground="White" FontSize="18.667" BorderBrush="#FF6E6E6E" Margin="0" DockPanel.Dock="Bottom" ItemsSource="{Binding DraftViewModel.RootChapters}" ItemTemplate="{DynamicResource ChapterTemplate}" ItemContainerStyle="{DynamicResource TreeViewItemStyle1}" />
        	</DockPanel>
            <GridSplitter HorizontalAlignment="Right" 
				VerticalAlignment="Stretch" 
				Grid.Column="1" ResizeBehavior="PreviousAndNext"
				Width="2" Background="Black" Foreground="Black" Cursor="SizeWE" IsTabStop="False"/>
            <TextBox TextWrapping="Wrap" Grid.Column="2" Margin="0" Background="#FFC8C8C8" FontSize="16" AcceptsReturn="True" AcceptsTab="True" VerticalScrollBarVisibility="Auto" Foreground="#FF040404"  DataContext="{Binding SelectedItem, ElementName=treeView1, Mode=OneWay}" Text="{Binding Text, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}" x:Name="txtText" FontFamily="/Drafter;component/Fonts/#Gentium Basic" >
                <TextBox.BorderBrush>
                    <LinearGradientBrush EndPoint="0,20" MappingMode="Absolute" StartPoint="0,0">
                        <GradientStop Color="#FFABADB3" Offset="0.05"/>
                        <GradientStop Color="#FFE2E3EA" Offset="0.07"/>
                        <GradientStop Color="#FFA3A3A3" Offset="1"/>
                    </LinearGradientBrush>
                </TextBox.BorderBrush>
            </TextBox>

            <GridSplitter HorizontalAlignment="Right" 
				VerticalAlignment="Stretch" 
				Grid.Column="3" ResizeBehavior="PreviousAndNext"
				Width="2" Background="Black" Margin="0" Foreground="Black" IsTabStop="False"/>
            <DockPanel x:Name="notesPanel" Grid.Column="4" Margin="0" Visibility="{Binding NotesVisible, Converter={StaticResource BooleanToVisibilityConverter}}" >
            	<TextBlock FontSize="24" Foreground="#FF6E6E6E" HorizontalAlignment="Center" FontStyle="Italic" FontWeight="Bold"  Background="#FF030303" Height="35" d:LayoutOverrides="Height" Text="Notes" VerticalAlignment="Center" DockPanel.Dock="Top" />

                <TextBox TextWrapping="Wrap" DataContext="{Binding SelectedItem, ElementName=treeView1, Mode=OneWay}" Text="{Binding Notes, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}" Background="#FF2D2D2D" FontSize="13.333" AcceptsReturn="True" AcceptsTab="True" VerticalScrollBarVisibility="Auto" Foreground="White"  x:Name="txtNotes" BorderBrush="#FF6E6E6E" CaretBrush="Black" DockPanel.Dock="Bottom" />

            </DockPanel>

        </Grid>
        <StackPanel x:Name="TopButtonPanel" Grid.Column="2" Grid.Row="0" Orientation="Horizontal" HorizontalAlignment="Right">
            <Viewbox Height="35">
                <Path Data="M680.1523,337.9292C680.3773,333.8902 678.6393,335.1872 677.0533,336.5332 676.3883,337.0992 674.1823,335.3842 674.6293,334.6362 676.7083,331.1632 674.5673,331.5032 672.5353,331.9592 671.6823,332.1502 670.5253,329.6082 671.2713,329.1522 674.7233,327.0402 672.6713,326.3482 670.6573,325.8092 669.8123,325.5852 669.9703,322.7932 670.8423,322.7372 674.8813,322.4732 673.3843,320.9052 671.8553,319.4912 671.2133,318.8982 672.6493,316.5012 673.4483,316.8562 677.1463,318.4992 676.5483,316.4162 675.8503,314.4532 675.5583,313.6292 677.9433,312.1752 678.4863,312.8602 680.9973,316.0362 681.4373,313.9122 681.7323,311.8492 681.8533,310.9842 684.6423,310.8052 684.8033,311.6632 685.5503,315.6402 686.9273,313.9662 688.1463,312.2762 688.6573,311.5682 691.2083,312.7052 690.9543,313.5402 689.7673,317.4102 691.7633,316.5672 693.6293,315.6362 694.4103,315.2462 696.1413,317.4392 695.5273,318.0602 692.6793,320.9362 694.8393,321.1172 696.9223,321.1582 697.7963,321.1752 698.3123,323.9232 697.4783,324.1882 693.6183,325.4092 695.4463,326.5732 697.2713,327.5792 698.0383,328.0002 697.2173,330.6742 696.3573,330.5192 692.3713,329.8082 693.4483,331.6902 694.5953,333.4272 695.0773,334.1582 693.1113,336.1392 692.4203,335.6042 689.2193,333.1262 689.3013,335.2922 689.5133,337.3652 689.5993,338.2332 686.9373,339.0722 686.5743,338.2782 684.8913,334.5972 683.9573,336.5542 683.1803,338.4852 682.8563,339.2952 680.1033,338.8012 680.1523,337.9292 M687.6463,328.7092C689.6873,326.7022 689.7153,323.4172 687.7083,321.3752 685.7023,319.3362 682.4173,319.3072 680.3743,321.3142 678.3343,323.3212 678.3053,326.6062 680.3123,328.6472 682.3193,330.6882 685.6053,330.7152 687.6463,328.7092 M681.4313,327.5472C680.0333,326.1242 680.0513,323.8322 681.4743,322.4332 682.8983,321.0332 685.1903,321.0542 686.5893,322.4762 687.9893,323.8992 687.9683,326.1912 686.5463,327.5902 685.1233,328.9892 682.8313,328.9702 681.4313,327.5472 M685.2853,326.2872C685.9883,325.5832 685.9883,324.4402 685.2853,323.7372 684.5813,323.0332 683.4373,323.0332 682.7353,323.7372 682.0313,324.4402 682.0313,325.5832 682.7353,326.2872 683.4373,326.9902 684.5813,326.9902 685.2853,326.2872" Fill="#FF6E6E6E" Stretch="Fill" RenderTransformOrigin="0.606,-11.012" Width="47.216" Height="50" VerticalAlignment="Bottom" >
                    <i:Interaction.Triggers>
                        <i:EventTrigger EventName="MouseLeftButtonDown">
                            <GalaSoft_MvvmLight_Command:EventToCommand Command="{Binding NavigateToCommand, Mode=OneWay}" CommandParameter="Options" />
                        </i:EventTrigger>
                    </i:Interaction.Triggers>
                </Path>
            </Viewbox>
            <Viewbox Height="35">
                <Path Data="M432.3857,269.5078L436.8927,264.9998 432.3847,260.4918C431.7997,259.9068,431.7997,258.9558,432.3847,258.3718L437.3717,253.3838C437.9567,252.7998,438.9067,252.7998,439.4917,253.3838L444.0007,257.8928 448.5077,253.3848C449.0927,252.7998,450.0437,252.7998,450.6277,253.3848L455.6157,258.3718C456.1997,258.9568,456.1997,259.9068,455.6157,260.4918L451.1077,264.9998 455.6147,269.5068C456.1997,270.0918,456.1997,271.0418,455.6147,271.6268L450.6277,276.6138C450.0427,277.1988,449.0927,277.1988,448.5077,276.6138L444.0007,272.1068 439.4927,276.6148C438.9077,277.1998,437.9577,277.1998,437.3727,276.6148L432.3857,271.6278C431.8007,271.0428,431.8007,270.0928,432.3857,269.5078" Fill="#FF6E6E6E" Stretch="Fill" RenderTransformOrigin="0.606,-11.012" Width="47.216" Height="50" VerticalAlignment="Bottom" >
                    <i:Interaction.Triggers>
                        <i:EventTrigger EventName="MouseLeftButtonDown">
                            <GalaSoft_MvvmLight_Command:EventToCommand Command="{Binding CloseApplicationCommand, Mode=OneWay}" CommandParameter="Options" />
                        </i:EventTrigger>
                    </i:Interaction.Triggers>
                </Path>
            </Viewbox>
        </StackPanel>
        <TextBox x:Name="chapterTitleTextBox" DataContext="{Binding SelectedItem, ElementName=treeView1, Mode=OneWay}" Text="{Binding Title}" FontSize="24" Foreground="#FF6E6E6E" HorizontalAlignment="Center" FontStyle="Italic" FontWeight="Bold" BorderBrush="{x:Null}" Background="#FF030303" Margin="0" Grid.Column="1" VerticalAlignment="Center" IsTabStop="False" />
        <Popup x:Name="menuPopup" Grid.Column="1" HorizontalAlignment="Left" Margin="90.9,30.166,0,0" Grid.Row="1" VerticalAlignment="Top" PlacementTarget="{Binding ElementName=MenuIcon}" StaysOpen="False">
            <Border x:Name="border" BorderBrush="White" BorderThickness="3" CornerRadius="3" Panel.ZIndex="1000" Background="#FF373737">
                <UniformGrid Rows="2">
                    <StackPanel Orientation="Vertical" Margin="3">
                        <Path Data="F1M381.667,4.52999999999997L380.976,4.52999999999997 380.976,3.86000000000001 381.667,3.86000000000001 381.667,4.52999999999997z M381.859,2.86000000000001L380.548,2.86000000000001 380.548,8.30999999999995C380.548,8.57999999999993,380.32,8.80999999999995,380.037,8.80999999999995L371.958,8.80999999999995C371.677,8.80999999999995,371.449,8.57999999999993,371.449,8.30999999999995L371.449,2.86000000000001 370.138,2.86000000000001C369.958,2.86000000000001,369.814,3,369.814,3.16999999999996L369.814,14.11 370.964,15.23 372.763,15.23 372.763,10.98C372.763,10.71,372.992,10.48,373.275,10.48L378.845,10.48C379.128,10.48,379.357,10.71,379.357,10.98L379.357,15.23 382.185,15.23 382.185,3.16999999999996C382.185,3,382.037,2.86000000000001,381.859,2.86000000000001" Fill="White" Stretch="Fill" RenderTransformOrigin="0.606,-11.012" Height="45.793" Width="46.227"  />
                        <TextBlock TextWrapping="Wrap" Text="Save" Foreground="White" FontSize="10.667" TextAlignment="Center"/>
                        <TextBlock TextWrapping="Wrap" Text="(Ctrl+S)" Foreground="White" FontSize="10.667" TextAlignment="Center"/>
                    </StackPanel>
                    <StackPanel Orientation="Vertical" Margin="3">
                        <Path Data="M680.1523,337.9292C680.3773,333.8902,678.6393,335.1872,677.0533,336.5332C676.3883,337.0992,674.1823,335.3842,674.6293,334.6362C676.7083,331.1632,674.5673,331.5032,672.5353,331.9592C671.6823,332.1502,670.5253,329.6082,671.2713,329.1522C674.7233,327.0402,672.6713,326.3482,670.6573,325.8092C669.8123,325.5852,669.9703,322.7932,670.8423,322.7372C674.8813,322.4732,673.3843,320.9052,671.8553,319.4912C671.2133,318.8982,672.6493,316.5012,673.4483,316.8562C677.1463,318.4992,676.5483,316.4162,675.8503,314.4532C675.5583,313.6292,677.9433,312.1752,678.4863,312.8602C680.9973,316.0362,681.4373,313.9122,681.7323,311.8492C681.8533,310.9842,684.6423,310.8052,684.8033,311.6632C685.5503,315.6402,686.9273,313.9662,688.1463,312.2762C688.6573,311.5682,691.2083,312.7052,690.9543,313.5402C689.7673,317.4102,691.7633,316.5672,693.6293,315.6362C694.4103,315.2462,696.1413,317.4392,695.5273,318.0602C692.6793,320.9362,694.8393,321.1172,696.9223,321.1582C697.7963,321.1752,698.3123,323.9232,697.4783,324.1882C693.6183,325.4092,695.4463,326.5732,697.2713,327.5792C698.0383,328.0002,697.2173,330.6742,696.3573,330.5192C692.3713,329.8082,693.4483,331.6902,694.5953,333.4272C695.0773,334.1582,693.1113,336.1392,692.4203,335.6042C689.2193,333.1262,689.3013,335.2922,689.5133,337.3652C689.5993,338.2332,686.9373,339.0722,686.5743,338.2782C684.8913,334.5972,683.9573,336.5542,683.1803,338.4852C682.8563,339.2952,680.1033,338.8012,680.1523,337.9292 M687.6463,328.7092C689.6873,326.7022,689.7153,323.4172,687.7083,321.3752C685.7023,319.3362,682.4173,319.3072,680.3743,321.3142C678.3343,323.3212,678.3053,326.6062,680.3123,328.6472C682.3193,330.6882,685.6053,330.7152,687.6463,328.7092 M681.4313,327.5472C680.0333,326.1242,680.0513,323.8322,681.4743,322.4332C682.8983,321.0332,685.1903,321.0542,686.5893,322.4762C687.9893,323.8992,687.9683,326.1912,686.5463,327.5902C685.1233,328.9892,682.8313,328.9702,681.4313,327.5472 M685.2853,326.2872C685.9883,325.5832,685.9883,324.4402,685.2853,323.7372C684.5813,323.0332,683.4373,323.0332,682.7353,323.7372C682.0313,324.4402,682.0313,325.5832,682.7353,326.2872C683.4373,326.9902,684.5813,326.9902,685.2853,326.2872" Fill="White" Stretch="Fill" RenderTransformOrigin="0.606,-11.012" Height="45.793" Width="46.227"  />
                        <TextBlock TextWrapping="Wrap" Text="Open" Foreground="White" FontSize="10.667" TextAlignment="Center"/>
                        <TextBlock TextWrapping="Wrap" Text="(Ctrl+O)" Foreground="White" FontSize="10.667" TextAlignment="Center"/>
                    </StackPanel>
                    <StackPanel Orientation="Vertical" Margin="3">
                        <Path Data="M613.415,278.4751L613.415,251.5251C613.415,250.7661,614.031,250.1501,614.79,250.1501L625.378,250.1501 634.585,259.3561 634.585,278.4751C634.585,279.2341,633.969,279.8501,633.211,279.8501L614.79,279.8501C614.031,279.8501,613.415,279.2341,613.415,278.4751 M631.833,259.0841L625.651,252.9021 625.651,258.1601C625.651,258.6691,626.066,259.0841,626.575,259.0841z" Fill="White" Stretch="Fill" RenderTransformOrigin="0.606,-11.012" Height="45.793" Width="33.227"  />
                        <TextBlock TextWrapping="Wrap" Text="New" Foreground="White" FontSize="10.667" TextAlignment="Center"/>
                        <TextBlock TextWrapping="Wrap" Text="(Ctrl+N)" Foreground="White" FontSize="10.667" TextAlignment="Center"/>
                    </StackPanel>
                    <StackPanel Orientation="Vertical" Margin="3">
                        <Path Data="M255.6699,158.8672L255.6699,148.5822 272.3199,148.5822 272.3199,155.7322 269.1849,158.8672z M268.8789,157.6162L271.0699,155.4312 268.8789,155.4312z M249.3809,153.4532L249.3809,140.1892C249.3809,139.4432,249.9839,138.8352,250.7309,138.8352L277.2619,138.8352C278.0079,138.8352,278.6169,139.4432,278.6169,140.1892L278.6169,153.4532C278.6169,154.1992,278.0079,154.8072,277.2619,154.8072L273.9369,154.8072 273.9369,147.1082 254.0689,147.1082 254.0689,154.8072 250.7309,154.8072C249.9839,154.8072,249.3809,154.1992,249.3809,153.4532 M255.6769,137.3842L255.6789,131.1332 272.3289,131.1322 272.3269,137.3832z" Fill="White" Stretch="Fill" RenderTransformOrigin="0.606,-11.012" Height="45.793" Width="46.227"  />
                        <TextBlock TextWrapping="Wrap" Text="Print" Foreground="White" FontSize="10.667" TextAlignment="Center"/>
                        <TextBlock TextWrapping="Wrap" Text="(Ctrl+P)" Foreground="White" FontSize="10.667" TextAlignment="Center"/>
                        <Path Data="M24.319,19" Fill="White" Height="0" Stretch="Fill" Width="0"/>
                    </StackPanel>
                    <StackPanel Orientation="Vertical" Margin="3">
                        <Path Data="M667.7988,154.5859L667.7988,146.7709 670.9398,146.7709 670.9398,153.0229 697.0738,153.0229 697.0578,146.7709 700.1998,146.7709 700.1998,154.5859C700.1998,155.4129,699.5278,156.0849,698.6998,156.0849L669.2988,156.0849C668.4708,156.0849,667.7988,155.4129,667.7988,154.5859 M683.9988,150.1899L675.0778,143.4479 679.0908,143.4479 679.0908,133.9149 688.5138,133.9149 688.5138,143.4479 692.9208,143.4479z" Fill="White" Stretch="Fill" RenderTransformOrigin="0.606,-11.012" Height="45.793" Width="46.227"  />
                        <TextBlock TextWrapping="Wrap" Text="Export" Foreground="White" FontSize="10.667" TextAlignment="Center"/>
                        <TextBlock TextWrapping="Wrap" Text="(Ctrl+E)" Foreground="White" FontSize="10.667" TextAlignment="Center"/>
                    </StackPanel>
                    <StackPanel Orientation="Vertical" Margin="3">
                        <Path Data="M667.7988,154.5859L667.7988,146.7709 670.9398,146.7709 670.9398,153.0229 697.0738,153.0229 697.0578,146.7709 700.1998,146.7709 700.1998,154.5859C700.1998,155.4129,699.5278,156.0849,698.6998,156.0849L669.2988,156.0849C668.4708,156.0849,667.7988,155.4129,667.7988,154.5859 M683.9988,150.1899L675.0778,143.4479 679.0908,143.4479 679.0908,133.9149 688.5138,133.9149 688.5138,143.4479 692.9208,143.4479z" Fill="White" Stretch="Fill" RenderTransformOrigin="0.606,-11.012" Height="45.793" Width="46.227"  />
                        <TextBlock TextWrapping="Wrap" Text="Save As" Foreground="White" FontSize="10.667" TextAlignment="Center"/>
                        <TextBlock TextWrapping="Wrap" Text="(Ctrl+Shift+S)" Foreground="White" FontSize="10.667" TextAlignment="Center"/>
                    </StackPanel>
                </UniformGrid>
            </Border>
        </Popup>
        <Viewbox HorizontalAlignment="Left" Margin="0" VerticalAlignment="Top" Height="35">
            <Path x:Name="MenuIcon" Data="M70.2778,455.9248C70.0838,455.9248 69.9078,455.8948 70.2588,455.9228 69.9048,455.8768 69.8168,455.8498 69.8918,455.8638 69.5498,455.7688 69.3878,455.6538 69.2818,455.5078 69.0308,455.2558 68.8758,454.9078 68.8768,454.5248L68.8768,437.2728C68.8758,436.8628,69.0518,436.4948,69.3308,436.2378L70.1288,434.8558C70.3788,434.4248,70.9858,434.0748,71.4838,434.0748L76.6418,434.0738C77.1408,434.0748,77.7468,434.4248,77.9958,434.8558L78.5808,435.8688 93.6508,435.8688C94.4248,435.8698,95.0528,436.4978,95.0528,437.2728L95.0528,440.7698 97.9908,440.7698C98.7648,440.7698,99.2568,441.2448,99.0908,441.8298L95.3558,454.8658C95.2298,455.3038 94.7688,455.6798 94.0098,455.8718 94.1118,455.8498 94.0238,455.8778 93.6678,455.9228 94.0358,455.8948 93.8428,455.9248 93.6498,455.9248z M70.8428,449.0548L72.9128,441.8298C73.0808,441.2448,73.8458,440.7698,74.6188,440.7698L93.2588,440.7698 93.2588,437.7418 76.9188,437.7418 76.1628,436.2318 71.9888,436.2318 71.8248,436.2358 70.8428,437.7418z" Fill="#FF6E6E6E" Stretch="Fill" RenderTransformOrigin="0.606,-11.012" MouseUp="MenuIcon_MouseUp" Height="35" Width="41.58" />
        </Viewbox>
        <Button Content="Button" HorizontalAlignment="Left" Height="35" Margin="0" Grid.Row="2" Style="{DynamicResource ButtonStyle2}" VerticalAlignment="Bottom" Width="42.549" Command="{Binding ToogleOutlineView, Mode=OneWay}" IsTabStop="False" Foreground="#FF6E6E6E">
        	<Button.Background>
        		<LinearGradientBrush EndPoint="0,1" StartPoint="0,0">
        			<GradientStop Color="#FFF3F3F3" Offset="0"/>
        			<GradientStop Color="#FFEBEBEB" Offset="0.5"/>
        			<GradientStop Color="#FFDDDDDD" Offset="0.5"/>
        			<GradientStop Color="White" Offset="1"/>
        		</LinearGradientBrush>
        	</Button.Background>
        </Button>
        <Button Content="Button" Grid.Column="2" HorizontalAlignment="Right" Height="35" Margin="0" Grid.Row="2" Style="{DynamicResource ButtonStyle1}" VerticalAlignment="Bottom" Width="42.549" d:LayoutOverrides="HorizontalAlignment" Command="{Binding ToogleNotesView, Mode=OneWay}" IsTabStop="False" Foreground="#FF6E6E6E">
        	<Button.Background>
        		<LinearGradientBrush EndPoint="0,1" StartPoint="0,0">
        			<GradientStop Color="#FFF3F3F3" Offset="0"/>
        			<GradientStop Color="#FFEBEBEB" Offset="0.5"/>
        			<GradientStop Color="#FFDDDDDD" Offset="0.5"/>
        			<GradientStop Color="White" Offset="1"/>
        		</LinearGradientBrush>
        	</Button.Background>
        </Button>
        
    </Grid>
</UserControl>
